package structuralPatterns.facade;

interface SystemOperation {
    void operation();
}

class AbstractSystem implements SystemOperation {
    public AbstractSystem() {
    }

    public void operation() {
        System.out.println("AbstractSystem operation");
    }
}

class ConcreteSystem1 extends AbstractSystem {
    @Override
    public void operation() {
        System.out.println("ConcreteSystem1 operation");
    }
}

class ConcreteSystem2 extends AbstractSystem {
    @Override
    public void operation() {
        System.out.println("ConcreteSystem2 operation");
    }
}

class Facade {
    private AbstractSystem system1;
    private AbstractSystem system2;

    public Facade() {
        system1 = new ConcreteSystem1();
        system2 = new ConcreteSystem2();
    }

    public void operation() {
        system1.operation();
        system2.operation();
    }
}

public class FacadePattern {
    public static void main(String[] args) {
        Facade facade = new Facade();
        facade.operation();
    }
}
